/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.hk.shop.entity.product;

import com.thinkgem.jeesite.modules.hk.sys.entity.user.HkUser;
import org.hibernate.validator.constraints.Length;
import com.fasterxml.jackson.annotation.JsonBackReference;
import java.util.List;
import com.google.common.collect.Lists;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 乐购产品评价Entity
 * @author 罗天文
 * @version 2018-05-19
 */
public class HkShopProductComment extends DataEntity<HkShopProductComment> {
	
	private static final long serialVersionUID = 1L;
	private HkShopProduct product;		// 产品id
	private HkUser user;		// 用户id
	private String content;		// 内容
	private HkUser replyUser;		// 回复人id
	private HkShopProductComment comment;		// 评论id
	private List<HkShopProductCommentImg> hkShopProductCommentImgList = Lists.newArrayList();		// 子表列表
	
	public HkShopProductComment() {
		super();
	}

	public HkShopProductComment(String id){
		super(id);
	}

	public HkShopProduct getProduct() {
		return product;
	}

	public void setProduct(HkShopProduct product) {
		this.product = product;
	}
	
	public HkUser getUser() {
		return user;
	}

	public void setUser(HkUser user) {
		this.user = user;
	}
	
	@Length(min=0, max=200, message="内容长度必须介于 0 和 200 之间")
	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}
	
	public HkUser getReplyUser() {
		return replyUser;
	}

	public void setReplyUser(HkUser replyUser) {
		this.replyUser = replyUser;
	}
	
	@JsonBackReference
	public HkShopProductComment getComment() {
		return comment;
	}

	public void setComment(HkShopProductComment comment) {
		this.comment = comment;
	}
	
	public List<HkShopProductCommentImg> getHkShopProductCommentImgList() {
		return hkShopProductCommentImgList;
	}

	public void setHkShopProductCommentImgList(List<HkShopProductCommentImg> hkShopProductCommentImgList) {
		this.hkShopProductCommentImgList = hkShopProductCommentImgList;
	}
}